#include <cstdio>
#include <cstring>
#include <cassert>
#include <cstdlib>
#include <set>
#include <map>
#include <vector>
#include <algorithm>
#include <numeric>
#include <list>
#include <queue>
#include <iostream>
#include <limits>
#include <string>
using namespace std;
#define forr(a, b) for (int a = 0; a < b; ++a)
#define eps 1e-9
#define inf 1e9
#define pb push_back


typedef pair<int, int> pii;
typedef long long ll;
typedef vector<int> vint;
template<class T>  T gcd(T a, T b){return b?gcd(b,a%b):a;}
int main(){
    int a,b,c;
    cin>>a>>b;
    c=gcd(a,b);
    a/=c,b/=c;
    if (a-b==1 || a-b==-1)
        cout<<"Equal";
    else if(a<b) cout<<"Dasha";
    else cout<<"Masha";
}